import request from '@/utils/request'

// 创建导购
export function createShopGuide(data) {
  return request({
    url: '/qd/shop-guide/create',
    method: 'post',
    data: data
  })
}

// 更新导购
export function updateShopGuide(data) {
  return request({
    url: '/qd/shop-guide/update',
    method: 'put',
    data: data
  })
}

// 删除导购
export function deleteShopGuide(id) {
  return request({
    url: '/qd/shop-guide/delete?id=' + id,
    method: 'delete'
  })
}

// 获得导购
export function getShopGuide(id) {
  return request({
    url: '/qd/shop-guide/get?id=' + id,
    method: 'get'
  })
}

// 获得导购分页
export function getShopGuidePage(query) {
  return request({
    url: '/qd/shop-guide/page',
    method: 'get',
    params: query
  })
}

// 导出导购 Excel
export function exportShopGuideExcel(query) {
  return request({
    url: '/qd/shop-guide/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
